<template>
	<view></view>
</template>

<script>
export default {
	data() {
		return {};
	},
	onLoad(options) {
		uni.scanCode({
			success: res => {
				console.log('res',res);
				this.macCode = res.path.split('?')[1].split('=')[1];
				uni.reLaunch({
					url: '/pages/index/index'
				});
				this.back();
			} 
		});
	},
	methods: {
		back() {
			uni.navigateBackMiniProgram({
				extraData: {
					originalDeviceCode: this.macCode
				},
				success(res) {}
			});
		}
	}
};
</script>

<style>
page {
	width: 100vw;
	height: 100vh;
	background-color: #000000;
}
</style>
